package com.zsummer.zero.thread;

/**
 * join()������ʹ��
 * ע��Դ��ʹ��wait����ʵ��join����
 * @author zhouyujiang
 *
 */
public class ThreadDemo7 {
	
	public static void main(String[] args) {
		Thread thread = new Thread(() -> {
			for (int i = 0; i < 100	; i++) {
				System.out.println(i);
			}
		});
		thread.start();
		try {
			thread.join();
		} catch (InterruptedException e) {
			e.printStackTrace();
		}
		System.out.println("end");
	}

}
